﻿<%@ Page Title="" Language="C#" MasterPageFile="~/Views/Shared/SiteMain.Master" Inherits="System.Web.Mvc.ViewPage<TvGuide.UI.Models.SearchData>" %>

<asp:Content ID="Content1" ContentPlaceHolderID="TitleContent" runat="server">
	 <%= Model.SearchTitle %></asp:Content>

<asp:Content ID="Content2" ContentPlaceHolderID="MainContent" runat="server">
    <script type="text/javascript">
        $(function () {
            $("#accordion").accordion({
                collapsible: true,
                autoHeight: false,
                navigation: true,
                offset: [5, 0]
            });


            $("#accordion img[title]").tooltip({
                effect: 'slide',
                position: 'center left'

            }).dynamic({ bottom: { direction: 'down', bounce: true} });

        });

	</script>

   <% if(Model.partstr.Count>0)
   { 
   %>
        <div class = "search-text-by-parts">
            <%: Model.SearchNotification %> 
       
            <% foreach(var ss in Model.partstr)
               {
            %>
               <span class = "Advance-Search-label-parts"  onclick="searchProgram('<%:ss %>')"><%: ss %></span>        
            <%
               }
            %>
            <%: Model.FOR_WORDS_LBL%>
        </div>
    <% 
    } 
    %>

    <% if (Model.SearchedProgramsList.Count != 0)
       {%>
            <div id="accordion">
           <% foreach (var item in Model.SearchedProgramsList) 
               { %>
 
                <%=Html.AcordionElement(item) %>
   

            <%} %>
            </div>
       <%} %>
    <%else
       {%>
          <%-- <p>Nothing is found</p>--%>
       <%} %>
</asp:Content>
